Exemplary embodiments of the present invention relate to a cache with a scratch pad memory structure and a processor including the same, and more particularly, to a cache with a scratch pad memory structure in which a scratch pad memory function is added to a cache structure and a processor including the same.
A processor is an apparatus that reads and analyzes instructions stored in an external storage apparatus to perform a specific operation using an operand designated by instructions and then, perform the specific function by programs stored in the external storage apparatus.
The processor is applied to various applications to perform complex and various functions. As the functions, the processor has been used for various applications, such as video encoding and decoding, audio encoding and decoding, network packet routing, system control, and the like. In order for the processor to use various applications as described above, there is a need to process instruction code patterns having various types suitable for each application.
In addition, since the processor is used in an apparatus supplying power in various forms from a base station for wireless communication to an apparatus supplied with power by a battery such as a wireless communication terminal, there is a need to increase performance of processor and reduce power consumption thereof.
The processor basically includes a core, a translation lookaside buffer (TLB), and a cache. Operations to be performed by the processor are defined by a combination of a plurality of instructions. That is, the instructions are stored in a memory and sequentially input to the processor and thus, the processor performs specific operations for each clock cycle.
The TLB serves to convert virtual address into physical address so as to drive operating system based applications. The cache temporarily stores the instructions stored in the external memory in a chip to increase a speed of the processor.
The core consumes much time of 10 to 100 cycles so as to read data from the memory, which is a factor of making the core be in an idle state for a long period of time. The cache is a unit for storing the instructions to be used by the core in a memory in a chip directly connected to the core. The reason why the cache is used is that the external memory may store large-capacity instructions of several Gbytes (256 Gbytes or more) or more, while the memory that can be implemented in the chip is about several Mbytes. That is, the cache serves to temporarily store an external large-capacity memory in the chip.
Therefore, the cache has a large effect on the performance of the processor. When the core requests the specific instructions, since the instructions are read from the external memory if there are no specific instructions requested by the processor in the cache, the cache is in an idle state while the instructions are read from the external memory, the processor transmits an address to the cache for each request, and the cache stores addresses corresponding to indexes for instruction codes stored therein, that is, tags in a tag memory. Further, each time the instruction code of the processor is requested, there is a need to access the tag memory for comparing the address with the tag. In addition, there is need to store the tags corresponding to the stored instruction codes.
In connection with this, when the specific applications are performed in advance, a method for compressing current cache memory data by calculating compression costs and dynamically supplementing it is suggested, which is not a method for actually reducing cache memory data.
In addition, a method for binding multiple instructions into a group and storing indexes therefor in an instruction memory has been proposed. However, when the instructions are read through the indexes, there is a need to load from the memory as many as the number of instructions within the group and this method is reducing the size of the instruction memory itself, and therefore, cannot actually save power.
The above-mentioned technical configuration is a background art for helping understanding of the present invention and does not mean related arts well known in a technical field to which the present invention pertains.